package itbour.onetouchshow.activity.myworks;

import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.support.v4.view.ViewPager;

import com.flyco.tablayout.SlidingTabLayout;

import java.util.ArrayList;

import butterknife.BindView;
import itbour.onetouchshow.R;
import itbour.onetouchshow.base.mvp.MVPBaseActivity;

/**
 * Created by guoh on 2018/7/10.
 * 功能描述：我的作品V3.0 增加原创作品
 * 需要的参数：
 */
public class MyWorksV3_0Activity extends MVPBaseActivity {
    @BindView(R.id.tab_layout)
    SlidingTabLayout tabLayout;
    @BindView(R.id.vp_works)
    ViewPager vpWorks;

    private ArrayList<Fragment> fragments;

    private String[] titles = new String[]{"模板作品", "原创作品"};

    @Override
    protected int getLayoutId() {
        return R.layout.ac_my_works_v3;
    }

    @Override
    protected void afterCreate(Bundle bundle) {
        fragments = new ArrayList<>();
        fragments.add(new ModuleProductFragment());
        fragments.add(new PersonalCreateFragment());
        tabLayout.setViewPager(vpWorks, titles, this, fragments);
    }

    @Override
    protected void initTitle() {
        super.initTitle();
        setTitleText("我的作品");
    }

    @Override
    public void loadSucceed(String result) {
    }

    @Override
    public void loadFaild(String error) {
    }

}
